home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 3: Developer Tools / Linux Cubed Series 3 - Developer Tools.iso / devel / debugger / bdm-linu.0 / bdm-linu / bdm-linux / bdm-util.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-04-27  |  994 b   |  44 lines

  1. /* bdm-util.h - define info for access to S-Record files */
  2.  
  3. #include    "sizedefs.h"
  4.  
  5. /* first define a structure for easy access to S-record info */
  6.  
  7. #define    SREC_MAXCOUNT        64
  8.  
  9. typedef struct {
  10.     int rectype;
  11.     int reclen;
  12.     LONG address;
  13.     char bytes [SREC_MAXCOUNT];
  14. } srecord;
  15.  
  16. /* some global data */
  17.  
  18. /* PrintEachRecord points to a string to be printed
  19.  * for each S-record successfully downloaded
  20.  */
  21.  
  22. extern char *PrintEachRecord;
  23.  
  24. /* ExecuteAddress contains address from S9 record
  25.  * starting execution address
  26.  */
  27.  
  28. extern LONG ExecuteAddress;
  29.  
  30. /* function calls in bdm-util.c */
  31.  
  32. int do_srec (srecord *, FILE *);
  33. void put_srec (srecord *, LONG);
  34. int do_load (LONG load_offset, char *infilename);
  35.  
  36. /* return values from do_srec () */
  37.  
  38. #define SREC_EOF        1       /* end of file before S9 record */
  39. #define SREC_S9         2       /* S9 record reached */
  40. #define SREC_CHECKSUM   3       /* checksum error in record */
  41. #define SREC_FORMAT     4       /* S-record format error */
  42.  
  43. /* end */
  44.